package com.jumi.microservice.dto.userWallet;

import com.jumi.microservice.common.exception.BaseException;
import com.jumi.microservice.common.page.PageDomain;
import io.swagger.annotations.ApiModelProperty;

/**
 * @author mazhao
 * @Date 2020-07-07 15:47
 */
public class WalletAccountRequest extends PageDomain {

    private static final long serialVersionUID = 7462975708589265044L;

    @ApiModelProperty("会员等级")
    private Integer memberLevel;

    @ApiModelProperty("手机号码")
    private String phoneNum;

    @Override
    public void checkRequest() {
        if(this.getMemberLevel()==null && (this.getPhoneNum()==null||this.getPhoneNum().trim().isEmpty())){
            throw new BaseException(500,"请先选择搜索条件");
        }
    }

    public Integer getMemberLevel() {
        return memberLevel;
    }

    public void setMemberLevel(Integer memberLevel) {
        this.memberLevel = memberLevel;
    }

    public String getPhoneNum() {
        return phoneNum;
    }

    public void setPhoneNum(String phoneNum) {
        this.phoneNum = phoneNum;
    }


}
